package com.sg.dto.integration.component;


import com.sg.common.dto.BaseDto;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.Date;
import java.util.Objects;


/**
 * @desc ConfOptionDto
 * @使用场景
 */
@Data
public class ConfOptionDto extends BaseDto implements Serializable {

    /**
     * 配置选项ID:
     */
    @ApiModelProperty("配置选项ID")
    private String confOptionId;

    /**
     * 配置选项标识:
     */
    @ApiModelProperty("配置选项标识")
    private String confOptionCode;

    /**
     * 配置选项名称:
     */
    @ApiModelProperty("配置选项名称")
    private String confOptionName;

    /**
     * 主体生命周期:
     */
    @ApiModelProperty("主体生命周期")
    private String subjectLifeCycle;

    /**
     * 操作人就职记录ID:
     */
    @ApiModelProperty("操作人就职记录ID")
    private String operationInductionId;

    /**
     * 操作时间:
     */
    @ApiModelProperty("操作时间")
    private Date operationTime;
    /**
     * 配置选项业务描述:
     */
    @NotNull(message = "配置选项业务描述不能为空")
    @ApiModelProperty("配置选项业务描述")
    private String confOptionDes;
    /**
     * 是否存档
     */
    @ApiModelProperty("是否存档")
    private String isArchive;
    /**
     * 操作时间
     */
    @ApiModelProperty("操作时间")
    private Date operateTime;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        if (!super.equals(o)) return false;
        ConfOptionDto that = (ConfOptionDto) o;
        return confOptionId == that.confOptionId && confOptionCode == that.confOptionCode && confOptionName == that.confOptionName && subjectLifeCycle == that.subjectLifeCycle && operationInductionId == that.operationInductionId && operationTime == that.operationTime && confOptionDes == that.confOptionDes && isArchive == that.isArchive && operateTime == that.operateTime;
    }

    @Override
    public int hashCode() {
        return Objects.hash(super.hashCode(), confOptionId, confOptionCode, confOptionName, subjectLifeCycle, operationInductionId, operationTime, confOptionDes, isArchive, operateTime);
    }

}
